package com.g8.pethospitallearnbackend.utils.responseUtil;

import lombok.Getter;

@Getter
public enum ResponseStatusEnum {
    SUCCESS(1, "操作成功"),
    SYSTEM_ERROR(0, "操作失败"),
    BAD_REQUEST(-1, "请求参数不合法或请求类型不正确"),
    MISS_PARAM(-2, "请求参数缺失"),
    DATA_NOT_EXIST(-3, "未查询到相关数据"),
    NO_ACCESS(-4, "无权限"),
    NOT_EXIST(404, "请求地址不存在");

    // Getter 方法
    // 状态码和状态信息
    private final int code;
    private final String msg;

    // 构造器
    private ResponseStatusEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

}
